package com.xiaotu.yapi.service;

import com.xiaotu.yapi.dao.DemoDao;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * 分类名称
 * 分类备注/描述
 *
 * @author Mr.zhang
 * @module yapi
 * @date 2022-01-19 22:05
 */
@Service
public class DemoService {

    private int abc = 0;

    public ThreadLocal<DemoDao> local = ThreadLocal.withInitial(DemoDao::new);

    public int getAbc() {
        abc++;
        return abc;
    }

    public int getDef() {
        return local.get().getDef();
    }

}
